﻿<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<%@include file="../common/base.jsp"%>
<title>折扣设置页</title>
<link rel="stylesheet" type="text/css"
	href="${ctx}/staticweb/css/index.css">
<script language="javascript" type="text/javascript">
	function click1(num) {

		if (document.getElementById(num).style.display == "block") {
			document.getElementById(num).style.display = "none";
		} else {
			document.getElementById(num).style.display = "block";

		}

	}
</script>
</head>
<body class="mian_bj">
	<form action="${ctx}/price/setDiscount.do" method="post">
		<div class="mian_top_01">
			<div class="mian_top_r"></div>
			<div class="mian_top_l"></div>
			<div class="mian_top_c"></div>
			<div class="mian_b">
				<div class="mian_b1">

					<p class="mian_b1_sousuo">
						<input name="smodel" placeholder="型号" type="text" value="${smodel}">
					</p>
					<p class="mian_b1_sousuo">
						<input name="scolor" placeholder="颜色" type="text" value="${scolor}">
					</p>
					<p class="mian_b1_sousuo">
						<input name="sdiscount" placeholder="折扣" type="text" value="${sdiscount}">
					</p>
					<p class="mian_b1_sousuo">
						<input type="submit" value="折扣提交"></a>
					</p>

					</a>
				</div>

				<table width="100%" border="0" cellpadding="0" cellspacing="0"
					class="mian_b_bg">
					<tr>
						<td width="5%" class="mian_b_bg_lm"><span></span>型号</td>
						<td width="5%" class="mian_b_bg_lm"><span></span>颜色</td>
						<td width="10%" class="mian_b_bg_lm"><span></span>原价（元）</td>
						<td width="10%" class="mian_b_bg_lm"><span></span>折扣</td>
						<td width="10%" class="mian_b_bg_lm"><span></span>现价（元）</td>
					</tr>
					<c:choose>
						<c:when test="${not empty list}">
							<c:forEach items="${list}" var="rowData">
								<tr>
									<td>${rowData.model}</td>
									<td>${rowData.color}</td>
									<td>${rowData.lastprice}</td>
									<td>${rowData.discount}</td>
									<td>${rowData.nowprice}</td>
								</tr>
							</c:forEach>
						</c:when>
						<c:otherwise>
							<tr>
								<td colspan="6">没有库存</td>
							</tr>
						</c:otherwise>
					</c:choose>
				</table>
			</div>
		</div>
	</form>
</body>
</html>
